package com.think.controller.User;

import com.think.bean.User;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Date;

@RestController
@RequestMapping("/user")
public class UserController {

    @RequestMapping("/{id}")
    public User getUserById(@PathVariable String id) {
        User user = new User();
        user.setId(id);
        user.setCreateTime(new Date());
        return user;
    }
}
